package licode.unisop.client.utils;

/**
 * 定义SSO客户端的错误码
 * SSO客户端的错误码开头为101
 *
 * @author WR
 */
public class SopErrorCode {
    // 客户端收到此错误码，需要获取location_url的值，重定向
    // public static final int NEED_LOCATION_URL = 101000;

    // 用户无权访问指定地址（需要配置用户对平台地址访问权限）
    public static final int NO_GRANT_ACCESS_URL = 101001;
    public static final String NO_GRANT_ACCESS_URL_MSG = "无权访问指定地址";

    // 用户未登录（对应非SSO需要先进行登录才能访问此地址）
    public static final int USER_NOT_LOGIN = SopAuthConst.USER_NOT_LOGIN;
    public static final String USER_NOT_LOGIN_MSG = SopAuthConst.USER_NOT_LOGIN_MSG;

    // 平台未认证（平台需要先接入统一认证中心）
    public static final int PLATFORM_NOT_AUTH = 611888;
    public static final String PLATFORM_NOT_AUTH_MSG = "平台未认证";

    public static final int PLATFORM_NOT_REGISTER = 101004;
    public static final String PLATFORM_NOT_REGISTER_MSG = "平台未注册";

    public static final int FORBIDDEN_TERMINAL = 101005;
    public static final String FORBIDDEN_TERMINAL_MSG = "终端无访问权限";

    public static final int FORBIDDEN_ROLE_GRAND = 101006;
    public static final String FORBIDDEN_ROLE_GRAND_MSG = "无访问权限";

    public static final int FORBIDDEN_PERM_GRAND = 101007;
    public static final String FORBIDDEN_PERM_GRAND_MSG = "无访问权限";

    public static final int SYSTEM_ERROR = 500;
    public static final String SYSTEM_ERROR_MSG = "系统繁忙，请稍后重试";

    public static final int FORBIDDEN = 401;
    public static final String FORBIDDEN_MSG = "访问的资源不存在";
}
